package com.hzncc.flowable_diboot.interfacelog.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.diboot.core.binding.query.BindQuery;
import com.diboot.core.binding.query.Comparison;
import com.diboot.core.entity.BaseModel;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Length;

import jakarta.validation.constraints.NotNull;

/**
* 接口日志 Entity 定义
* @author MyName
* @version 1.0
* @date 2024-09-05
* Copyright © MyCorp
*/

@TableName("mdl_interface_log")
@Getter @Setter @Accessors(chain = true)
public class InterfaceLog extends BaseModel {
    private static final long serialVersionUID = 1298115673109841482L;

    /**
     * 租户
     */
    @NotNull(message = "租户不能为空")
    @TableField()
    private String tenantId;

    /**
     * 编码
     */
    @Length(max=100, message="编码长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String code;

    /**
     * 名称
     */
    @Length(max=100, message="名称长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String name;

    /**
     * 流向
     */
    @Length(max=100, message="流向长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String direction;

    /**
     * 耗时
     */
    @Length(max=100, message="耗时长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String timeout;

    /**
     * 请求（接收）参数
     */
    @TableField()
    private String request;

    /**
     * 返回参数
     */
    @TableField()
    private String respons;

    /**
     * 异常
     */
    @TableField()
    private String exception;


}